CoreOne Web Services - Tier 4
Setting Up User Roles and Permissions

Access to CoreOne via Web Services utilizes the same security, roles, permissions and access control rules that human users experience through the web interface. In order to utilize any CoreOne Web Service, you will need to set up the appropriate user roles and permissions.

To set up a new role that is able to access CoreOne web service you log into the CoreOne web interface as a 'superuser' and go to configuration/roles menu. For this example in the role menu we will create a new role called 'Basic Web Services'.



Once the new role has been created, we now need to set up user permissions for a user to be able to fully utilize CoreOne Web Services. In the Roles index page select permissions on the desired user role, you will be brought to the permissions index for that specified role.




 Then select 'create new permission'. In this example we will set up user permissions for the use of the 'LimsTestsIndex' web service.



The 'controller' field in the permissions create is the name of the web service being used. For example AnimalsIndex is in the Animals web service and BreedsIndex is in the ReferenceData web service.

The 'action' field in the permissions create is the method name of the web service. For example 'PeopleShow' method in the People web service and 'LimsSpecimensIndex' method in the LimsSpecimens web service.

The 'format' field must be set to 'WS' for the permission to be correctly set up.

Another example for creating a permission for the 'VaccinationsIncompleteProcess' method in the 'VaccinationsIncomplete' web service.



Once the role and permissions have been created you can flush the cache or restart the server for the new permissions to take effect.



Remarks:
                
The controller name and action name must be written in CamelCase (E.g. ReferenceData) style rather than snake_case (E.g. reference_data) style.